print upto 1 decimal place python

102

print upto 1 decimal place python -

print("{:.1f}".format(number)) # Python3
print "%.1f" % number          # Python2

Comments

Submit
0 Comments